<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>网页导航案例</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        body {
            line-height: 1;
        }

         ul {
            list-style: none;
        }

        .box ul {
            width: 650px;
            height: 50px;
            background-color: #ffc0cb;
            text-align: center;
        }

        .box ul li {
            float: left;
        }

        .box ul li a {
            width: 80px;
            height: 50px;
            color: #fff;
            text-decoration: none;
            float: left;
            line-height: 48px;
            box-sizing: border-box;
        }

        .box ul li a:hover {
            background-color: #008000;
        }
    </style>
</head>

<body>
    <div class="box">
        <ul>
            <li><a href="#">新闻1</a></li>
            <li><a href="#">新闻2</a></li>
            <li><a href="#">新闻3</a></li>
            <li><a href="#">新闻4</a></li>
            <li><a href="#">新闻5</a></li>
            <li><a href="#">新闻6</a></li>
            <li><a href="#">新闻7</a></li>
            <li><a href="#">新闻8</a></li>
        </ul>
    </div>
    

</body>

</html>